package com.fezs.common.enums;

import cn.hutool.core.util.EnumUtil;
import lombok.AllArgsConstructor;
import lombok.Getter;

@Getter
@AllArgsConstructor
public enum YesNoEnum implements BaseEnum<Integer> {

    YES(1 ,"是"),
    NO(0 , "否");

    private final Integer code;
    private final String descp;

    public static YesNoEnum getEnumByCode(Integer code){
        switch (code) {
            case 0:
                return NO;
            case 1:
                return YES;
        }
        return null;
    }
}
